//
//  YTRecommendCell.m
//  CllForIOS
//
//  Created by qiyun on 2018/3/20.
//  Copyright © 2018年 aRui. All rights reserved.
//

#import "YTRecommendCell.h"
#import "UILabel+MultipleLines.h"
@interface YTRecommendCell ()

@end
@implementation YTRecommendCell
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
        [self makeUI];
    }
    return self;
}

- (void)makeUI{
    UILabel *title =[[UILabel alloc]init];
    title.textColor=[UIColor blackColor];
    title.font=KFONT_medium(13);
    title.text=@"设置账号:";
    [self.contentView addSubview:title];
    self.title = title;
    //
    UILabel *destitle =[[UILabel alloc]init];
    destitle.textColor=[UIColor blackColor];
    destitle.font=KFONT(12);
    destitle.text=@"此处不要超过个字啦啦啦啦啦 啦啦啦啦拉拉拉拉啦啦hhhhhhhhhhhhhhhhhhhhhhh";
    destitle.numberOfLines=0;
    [self.contentView addSubview:destitle];
    self.destitle = destitle;
    
    UIImageView*icon=[[UIImageView alloc]init];
    icon.image=IMAGE(@"icon5");
    
    [self.contentView addSubview:icon];
    self.icon=icon;
    
}
-(void)layoutSubviews{
    [super layoutSubviews];
    
    
    self.icon.frame=CGRectMake(15, AfW(33), 38, 38);
    CGPoint iconcenter= self.icon.center;
    iconcenter.y=self.contentView.frame.size.height/2;
    self.icon.center=iconcenter;
    
    
    self.title.frame=CGRectMake(CGRectGetMaxX(self.icon.frame)+8, AfW(33), 66, 13);
    CGPoint titlecenter= self.title.center;
    titlecenter.y=self.contentView.frame.size.height/2;
    self.title.center=titlecenter;
    
//        self.destitle.frame=CGRectMake(CGRectGetMaxX(self.title.frame)+21, AfW(33), detailsLabelSize.width, detailsLabelSize.height);
//        CGPoint center= self.destitle.center;
//        center.y=self.contentView.frame.size.height/2;
//        self.destitle.center=center;
    self.destitle.frame = CGRectMake(CGRectGetMaxX(self.title.frame)+21, 12, SCREEN_W-CGRectGetMaxX(self.title.frame)-21-60, 50);
}

@end
